<template>
    <div class="notice">
        <van-nav-bar title="公告" left-arrow @click-left="onClickLeft" />
        <div class="list">
            <div class="noticeTit">
                <div class="time">2023年8月13日 14:07</div>
                <div class="tit">
                    <p>谢谢谢谢谢谢</p>
                    <span>喜喜喜喜喜喜喜喜喜喜嘻嘻嘻嘻嘻嘻嘻喜喜喜喜喜喜喜喜喜喜</span>
                </div>
            </div>
        </div>
    </div>
</template>

<script lang="ts">
import { reactive, toRefs, onMounted } from 'vue'

export default {
    name: "Notice",
    setup() {
        const state = reactive({
            count: 0,
        })
        // 定义onClickLeft方法
        const onClickLeft = () => history.back();

        // 如果需要在组件挂载后执行某些操作，可以使用onMounted
        onMounted(() => {
            // 组件挂载后的逻辑
        });

        return {
            ...toRefs(state),
            onClickLeft,
        };
    }
}
</script>

<style scoped lang="less">
.notice {
    background: #F6F7F9;
    width: 100%;
    height: 100vh;

    .van-nav-bar {
        height: 52px;
    }

    .list {
        padding: 0 15px;

        .noticeTit {
            padding: 0 15px;
            display: flex;
            justify-content: space-between;
            flex-direction: column;
            align-items: center;

            .time {
                margin-top: 18px;
                font-size: 14px;
                color: #3D3D3D;
            }

            .tit {
                display: flex;
                justify-content: flex-start;
                flex-direction: column;
                align-items: flex-start;

                p {
                    text-align: left;
                    font-size: 16px;
                    color: #3D3D3D;
                    margin: 16px 0;
                }

                span {
                    text-align: left;
                    font-size: 14px;
                    color: #666666;
                }
            }
        }
    }
}

:deep(.van-nav-bar__left .van-badge__wrapper) {
    color: #272635;
}
</style>